﻿#pragma once

#include <QMainWindow>
#include <QWidget>
#include "ui_secmainwindow.h"
#include <iostream>
#include <string>
#include "QString"

using namespace std;
//using std::string;

class SecMainWindow : public QMainWindow
{
	Q_OBJECT

public:
	SecMainWindow(QWidget *parent = Q_NULLPTR);
	~SecMainWindow();

	QString stringToqstring(string str)
	{
		return QString::fromLocal8Bit(str.data());
	}

	string qstringTostring(QString qstring)
	{
		return (const char*)qstring.toLocal8Bit();
	}

	void setMainWindow(QMainWindow *parent) {
		this->parent = parent;
	}

	//重写绘图事件
	void paintEvent(QPaintEvent *);
private slots:
	void on_pushButton_clicked();

private:
	Ui::SecMainWindow ui;
	QMainWindow *parent;

};
